Repository navigation
Size Reservations - #80
Conversation
| adminCmd.AddCommand(newPartitionCmd(c)) | ||
| adminCmd.AddCommand(newProjectCmd(c)) | ||
| adminCmd.AddCommand(newSizeCmd(c)) | ||
| adminCmd.AddCommand(newSizeReservationCmd(c)) |
There was a problem hiding this comment.
Maybe we should make this command a child of size?
| // the admin api does not offer a dedicated get call for size reservations, | ||
| // so we filter the list by the given id. |
There was a problem hiding this comment.
The question is why... in the repository the get function is implemented. 😅
There was a problem hiding this comment.
Wait... I think I found a get in the normal API and not the Admin API?
| func amountFromCLI() *int32 { | ||
| amount := viper.GetInt32("amount") | ||
| if amount <= 0 { | ||
| return nil | ||
| } | ||
|
|
||
| return new(amount) | ||
| } |
There was a problem hiding this comment.
pointer.PointerOrNil should be cleaner than ignoring this flag silently.
| "github.com/spf13/cobra" | ||
| ) | ||
|
|
||
| // AdminSizeReservation lists all size reservations across projects, used for admin completions. |
| "project": func(a, b *apiv2.SizeReservation, descending bool) multisort.CompareResult { | ||
| return multisort.Compare(a.Project, b.Project, descending) | ||
| }, | ||
| "size": func(a, b *apiv2.SizeReservation, descending bool) multisort.CompareResult { |
There was a problem hiding this comment.
Filter by amount might be interesting?
I wanted to add the Size Reservation Get to API, but there is one in the non-admin API.
Gerrit91
left a comment
There was a problem hiding this comment.
Added --project flag to admin size reservation get in order not to do the search and added the normal API endpoints. Hope, this is fine!
Description
Size Reservations where missing
Used AI-Tools ✨